home *** CD-ROM | disk | FTP | other *** search
/ ETO Development Tools 1 / ETO Development Tools 1.iso / Tools - Objects / MacApp / Unsupported Samples / MacApp Drafter / Source / MMacApp® Drafter.cp < prev    next >
Encoding:
Text File  |  1990-07-13  |  1.3 KB  |  56 lines  |  [TEXT/MPS ]

  1. /*******************************************************************************
  2. *
  3. * Application:   MacApp® Drafter, a sample C++ program by Danie Underwood
  4. *
  5. * File:   MMacApp® Drafter.cp
  6. *
  7. * Description: Main Program
  8. *
  9. * Apple Integrated Systems
  10. *
  11. * ©1990 Apple Computer, Inc. All rights reserved.
  12. *
  13. ********************************************************************************/
  14.  
  15.  
  16. #define  __MDrafter__
  17.  
  18. #if qDebug
  19. #include <stdio.h>
  20. #include <iostream.h>
  21. #endif qDebug
  22.  
  23. #include <UMacApp.h>
  24. #include <UPrinting.h>
  25. #include <UGridView.h>
  26. #include <UTEView.h>
  27. #include <UDialog.h>
  28. #include <UMacApp® Drafter.h>
  29.  
  30. #pragma segment Main
  31. void main()
  32. {
  33.     TDrafterApplication *gDrafterApplication;                // The application object
  34.  
  35.     InitToolBox();                                        // Essential toolbox and utilities
  36.  
  37.     if (ValidateConfiguration(&gConfiguration)) {        // Make sure we can run
  38.  
  39.         InitUMacApp(12);                                // Initialize MacApp; 12 calls to MoreMasters
  40.  
  41. #if qDebug
  42.     cout.sync_with_stdio();
  43. #endif qDebug
  44.  
  45.         InitUTEView();
  46.         InitUDialog();
  47.         InitUGridView();
  48.  
  49.         FailNIL(gDrafterApplication=new TDrafterApplication);    // Allocate a new application object
  50.         gDrafterApplication->IDrafterApplication();                // Initialize that new object
  51.         gDrafterApplication->Run();                            // Run the application.
  52.     }
  53.     else
  54.         StdAlert(phUnsupportedConfiguration);
  55. };
  56.